﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;

namespace MaskDemo
{
    /// <summary>
    /// MaskWindowTest.xaml 的交互逻辑
    /// </summary>
    public partial class MaskWindowTest : Window
    {
        public MaskWindowTest()
        {
            InitializeComponent();
        }
        private void ShowCustomPopup()
        {
            var customContent = new CustomPopupContent();

            // 配置弹窗参数
            PopupService.Show(
                content: customContent,
                closeCallback: () => MessageBox.Show("弹窗已关闭"),
                maskBrush: new SolidColorBrush(Color.FromArgb(200, 30, 30, 30)),
                closeOnClickMask: false
            );

            // 订阅自定义事件
          
        }
        private void Button_Click(object sender, RoutedEventArgs e)
        {
            ShowCustomPopup();
        }

        
    }
}
